/*

Dofile: figure2_appendix.do 

Date: Dec. 10, 2016 
Aim: Present the distribution of intra-firm and arm's length prices

Input: base_for_reg.dta 
Output: figure2_appendix.xls 
Reported in the Online Appendix: "Figure A.2 – Distribution of intra-firm and arm’s length prices"

*/  

cd $datapath
use base_for_reg, clear 

gr tw (kdensity luv  if type==1 & tarif!=.) (kdensity luv if type==0 & tarif!=., lp(dash)),  legend(lab(1 "Intra-firm)")  lab(2 "Arm's length")) ytitle("") xtitle("Unit value by firm-product-country (log) ")
gr export $resultpath/$threshold/figure2_appendix.eps, replace  
